export default {
	reverseLoginStatus(state) {
		return state.hasLogin = !state.hasLogin
	},
	swiperCurrent(state) {
		return state.swiperCurrent
	},
	// 是否为个人账号
	isEnterprise(state){
		let flag= false;
		var enterprise = [1, 2, 6, 9, 10]
		var personal = [3,4, 5, 7, 8]
		var user = state.userInfo;
		// 获取所有角色信息
		let userType = user.account_type.split(",").map(item=>parseInt(item))
		for(let i = 0 ; i < userType.length; i ++){
			if(enterprise.includes(userType[i])){
				flag = true;
				return flag;
			}
		}
		
		return flag;
	}
}